-
Notifications
You must be signed in to change notification settings - Fork 230
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add helpful error message for failed julia dependency imports #2359
add helpful error message for failed julia dependency imports #2359
Conversation
I had intended this to catch the exception but specified the wrong type, it should be catching a |
Codecov Report
@@ Coverage Diff @@
## main #2359 +/- ##
==========================================
- Coverage 48.12% 47.69% -0.43%
==========================================
Files 110 110
Lines 30654 30518 -136
Branches 7994 7952 -42
==========================================
- Hits 14753 14557 -196
- Misses 14365 14444 +79
+ Partials 1536 1517 -19
... and 13 files with indirect coverage changes 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
since this issue will only cause an exception to be raised later on during execution, it makes more sense to raise a more helpful exception here
this is a barebones file that currently only tests the new import logic. more importantly, it demonstrates that we may be able to add more test coverage with clever use of patching and magicmock
I welcome input on whether this should raise a warning or an error, as well as what the content of the message should be. I have also added a test file that bypasses the issue with nosetests and rms being incompatible. The python docs provide a great example on patching |
...sigh, this was working on my local install. Will keep looking at it. |
This will be resolved in #2443 |
Motivation or Problem
Currently when RMG tries to import the Julia dependencies, a failed import is simply ignored due to testing limitations.
Description of Changes
Issues a warning if the import of the Julia dependencies fails, but only when not in the testing mode.
Testing
I built an environment without the Julia dependencies properly built to verify that the warning would be issued.
Reviewer Tips
The message should be more helpful, maybe pointing toward the install directions or some relevant GitHub issues.